package fanxing;

public class TextPerson {
    public static void main(String[] args) {
        Person1 person1 = new Person1();
        person1.setX(23);
        person1.setY(99.9);
        person1.setZ("男生");
        System.out.println("(Integer)person1.getX() = "
                + (Integer) person1.getX());
        System.out.println("(Double)person1.getY() = "
                + (Double) person1.getY());
        System.out.println("(String)person1.getZ() = "
                + (String) person1.getZ());
        Person2 person2 = new Person2();
        person2.setX(25);
        person2.setY(33.3);
        person2.setZ("sss");
        System.out.println("person2.getX() = " + person2.getX());
        System.out.println("person2.getY() = " + person2.getY());
        System.out.println("person2.getZ() = " + person2.getZ());
        person1.setX(23);
        person1.setY(99.9);
        person1.setZ("男生");
        System.out.println("person2.getX() = " + person1.getX());
        System.out.println("person2.getY() = " + person1.getY());
        System.out.println("person2.getZ() = " + person1.getZ());
    }
}
